package net.util.jport.ports.jdbc;

import net.util.jenco.erl.ErlTerm;
import net.util.jport.core.JPortApplicationExit;
import net.util.jport.core.JPortMicroRunner;

import java.util.Map;
import java.util.TreeMap;
import java.io.Reader;
import java.io.Writer;

/**
 * I implement the main loop logic.
 */
public class MainRunner extends JPortMicroRunner {

    private final Main.ConnectionConfig connConfig;

    private final Map<Integer,ConnectionHandler> conns;

    public MainRunner(Reader rin, Writer wout, Main.ConnectionConfig connConfig) {
        super(rin, wout);
        this.connConfig = connConfig;
        this.conns = new TreeMap<Integer, ConnectionHandler>();
    }

    protected void processApplicationMessage(ErlTerm message) throws JPortApplicationExit {
        throw new RuntimeException("unimplemented");
    }

    protected void stopApplication(ErlTerm reason) {
        throw new RuntimeException("unimplemented");
    }


}
